package hn.sigit.model.hnd.administrative;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

@Entity
@org.hibernate.annotations.Proxy(lazy=false)
@Table(name="HND_TransactionMetaData", schema="hnd_administrative")
@Inheritance(strategy=InheritanceType.JOINED)
public class HND_TransactionMetaData {
	private long id;
	private HND_TransactionType type;
	private HND_TransactionSubType name;
	private boolean canMutateRights;
	private boolean canSplit;
	private boolean canMerge;
	private boolean canEditData;
	
	
	@Id
	@Column(name="ID", nullable=false)
	@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="hnd_requestmetadata_id_gen")
	@SequenceGenerator(name="hnd_requestmetadata_id_gen", sequenceName="hnd_requestmetadata_id_seq", allocationSize=1)
	public long getId() {
		return id;
	}
	public void setId(long id) {
		this.id = id;
	}
	
	@Column(name="Name", nullable=false)
	@Enumerated(EnumType.STRING)
	public HND_TransactionSubType getName() {
		return name;
	}
	public void setName(HND_TransactionSubType name) {
		this.name = name;
	}
	
	@Column(name="Type", nullable=false)
	@Enumerated(EnumType.STRING)
	public HND_TransactionType getType() {
		return type;
	}
	public void setType(HND_TransactionType type) {
		this.type = type;
	}
	
	@Column(name="CanMutateRights", nullable=false)
	public boolean isCanMutateRights() {
		return canMutateRights;
	}
	public void setCanMutateRights(boolean canMutateRights) {
		this.canMutateRights = canMutateRights;
	}

	@Column(name="CanSplit", nullable=false)
	public boolean isCanSplit() {
		return canSplit;
	}
	public void setCanSplit(boolean canSplit) {
		this.canSplit = canSplit;
	}
	
	@Column(name="CanMerge", nullable=false)
	public boolean isCanMerge() {
		return canMerge;
	}
	public void setCanMerge(boolean canMerge) {
		this.canMerge = canMerge;
	}

	@Column(name="CanEditData", nullable=false)
	public boolean isCanEditData() {
		return canEditData;
	}
	public void setCanEditData(boolean canEditData) {
		this.canEditData = canEditData;
	}	
}
